import { IRoom } from '@/interface/common'

export interface IGetQueueListValidate{
  RoomId: string
  QueueId?: string
  DoctorId?: string
}

export interface IQueueDataItem {
  Name: string;
  QueueNo: string;
  QueueType: number;
  TimeSection?: any;
}

export interface IQueueTimeDateItem{
  TimeSection: string
  Name: string
  IsVisit: number
  RegType: number
}

export interface IQueueData {
  DoctorNo: string
  DoctorName: string
  DoctorLevel: string
  DoctorInfo: string
  DeptCode: string
  DeptName: string
  RoomName: string
  RoomId: string
  CurList: IQueueDataItem[]
  WaitList: IQueueDataItem[]
  TimeSectionList: IQueueTimeDateItem[]
  IsCall: number
  CallName: string
  CallQueueNo: string
}

export interface IQueueItem{
  ID: string
  RoomId: string
  Room?: IRoom
  Info: string
  Data?: IQueueData
  CreateTime: string
}

export interface IRoomQueue{
  RoomId: string
  ActiveQueue: IQueueItem
  List: IQueueItem[]
}

export interface IReservationInspectionQuery{
  RoomId: string
  CardNo?: string
  InHosNo?: string
}

export interface IReservationPayAndRegisterQuery{
  DeptId:string
  CardNo: string
  DoctorCode: string
}

export interface IReservationPayAndRegisterResponse{
  AppointmentId:string
  QueueNo: string
  VisitNo: string
  SerialNo:string
  ClinicFee: string
  ExamFee: string
  ActualPayFee:string
  RoomAddress: string
  RoomName:string
  VisitType: '无优惠' | '免挂号费' | '全免' | '面诊查费'
  OfferType: '初诊' | '复诊' | '回诊'
}

export interface IPayAndSignQuery{
  RoomId: string
  CardNo: string
  ApplyNos: string
}

export interface IReservationInspectionItem {
  itemName: string
  itemCode: string
  checkPoint: string
  payAmount: string
}

export interface IReservationListQuery{
  CardNo: string
}

export interface IReservationInspection {
  applyNo: string
  applyTime: string
  visitNo: string
  cardNo: string
  patientName: string
  patientAge: string
  patientSex: string
  itemTypeName: string
  applyDoctorCode: string
  applyDoctorName: string
  applyDeptCode: string
  applyDeptName: string
  examDeptCode: string
  examDeptName: string
  payState: string
  items: IReservationInspectionItem[]
}

export interface IAddCreditQuery{
  Amount: number
  Use: '门诊充值' | '住院押金充值' | '缴费'
  PatientId: string
}

export interface ISysPay {
  PatientId: string;
  Amount: number;
  OutOrderNo: string;
  PayUrl: string;
  PayStatus: '待支付' | '支付中' | '支付成功' | '支付失败'
  RefundStatus: string;
  PayTime: Date;
  Use: string;
  UseStatus: string;
  CreateTime: Date;
  ClientId: string;
  UpdateTime: Date;
  ID: string;
}

export interface IActiveNames{
  RoomId: string
  Name: string
}

export interface IReservationListResponseData{
  empNumber: string
  doctorName: string
  timesection: string
  appointmentId: string
  address: string
  dLevel: string
  flag: string
  payStatus: string
  isSignAble: string
}

export interface IReservationListResponse{
  YEAR: string
  DAY: string
  DATA: IReservationListResponseData[]
}

export interface IReservationSignQuery{
  AppointmentId: string
}

export interface IGetReturnVisitListQuery{
  CardNo: string
}

export interface IReturnVisitListData{
  Date: string
  SourceId: string
  PassWord: string
  DeptName: string
  PatientName: string
  DoctorTitle: string
  Gender: number
  PatientId: string
  EmpNumber: string
  DeptId: string
  LevelName: any
  Section: string
  CardNo: string
  IdNo: string
  DoctorName: string
  AgeStr: string
  AgeUnit: string
  Phone: string
  Id: string
  DeptCode: string
  VisitNo: string
  Age: number
}

export interface IReturnVisitValidate{
  id: string
  cardNo: string
  patientId: string
  empNumber: string
  deptId: string
}
